package com.hspedu.newData.LCR;
/**
 * @Author: yh
 * @description: 
 * @CreateTime: 2025-05-20 
 * @Version: 1.0
 */

public class LCR127跳跃训练 {

    public int trainWays(int num) {
        if (num < 2){
            return 1;
        }

        int[] dp = new int[num+1];

        dp[0] = 1;
        dp[1] = 1;

        for (int i = 2; i <= num; i++) {
            dp[i] = (dp[i-2] + dp[i-1])%1000000007;
        }
        return dp[num];
    }

}
